/*** Eclipse Class Decompiler plugin, copyright (c) 2012 Chao Chen (cnfree2000@hotmail.com) ***/
package com.qihoopp.qcoinpay;

import android.app.Activity;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.RelativeLayout;
import android.widget.RelativeLayout.LayoutParams;
import android.widget.TextView;

public final class af extends RelativeLayout {
    private Activity a;
    private View b;
    private TextView c;

    public af(Activity paramActivity, View paramView) {
        super(paramActivity);
        this.a = paramActivity;
        paramActivity = bi.a(paramActivity);
        setBackgroundDrawable(paramActivity.a("bg_titlebar.png"));
        setPadding(cz.a(this.a, 8.0F), 0, cz.a(this.a, 8.0F), 0);
        if (paramView != null) {
            this.b = paramView;
            (paramActivity = (RelativeLayout.LayoutParams) paramView.getLayoutParams()).addRule(9, -1);
            paramActivity.addRule(15, -1);
            addView(this.b, paramActivity);
        }
        this.c = new TextView(this.a);
        this.c.setGravity(17);
        this.c.setTextSize(20.0F);
        this.c.setTextColor(-1);
        this.c.setSingleLine();
        this.c.setText(a.a(b.u));
        paramActivity = new RelativeLayout.LayoutParams(-1, -1);
        paramView = cz.a(this.a, 80.0F);
        paramActivity.leftMargin = paramView;
        paramActivity.rightMargin = paramView;
        addView(this.c, paramActivity);
    }

    public final void a(View.OnClickListener paramOnClickListener) {
        this.b.setOnClickListener(paramOnClickListener);
    }
}